<?php

namespace common\entities\myhtsq;

use Yii;

/**
 * This is the model class for table "myscrm_erp_station".
 *
 * @property string $StationGUID
 * @property string $StationName
 * @property integer $StationType
 * @property string $Memo
 * @property string $StationCode
 * @property string $OrderCode
 * @property string $ParentStationGUID
 * @property string $HierarchyCode
 * @property string $BUGUID
 * @property string $ProjGUID
 * @property integer $IsProjManager
 * @property string $GlobalStationGUID
 * @property string $CompanyGUID
 * @property string $XcLevel
 * @property string $LxLevle
 * @property string $Zyx
 * @property string $MajorParentStationGUID
 */
class ErpStationEntity extends \common\entities\ConfigEntity
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return 'myscrm_erp_station';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['StationGUID'], 'required'],
            [['StationType', 'IsProjManager'], 'integer'],
            [['StationGUID', 'StationName', 'XcLevel', 'LxLevle', 'Zyx'], 'string', 'max' => 50],
            [['Memo'], 'string', 'max' => 200],
            [['StationCode', 'OrderCode', 'ParentStationGUID', 'BUGUID', 'ProjGUID', 'GlobalStationGUID', 'CompanyGUID', 'MajorParentStationGUID'], 'string', 'max' => 100],
            [['HierarchyCode'], 'string', 'max' => 500]
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'StationGUID' => 'Station Guid',
            'StationName' => 'Station Name',
            'StationType' => 'Station Type',
            'Memo' => 'Memo',
            'StationCode' => 'Station Code',
            'OrderCode' => 'Order Code',
            'ParentStationGUID' => 'Parent Station Guid',
            'HierarchyCode' => 'Hierarchy Code',
            'BUGUID' => 'Buguid',
            'ProjGUID' => 'Proj Guid',
            'IsProjManager' => 'Is Proj Manager',
            'GlobalStationGUID' => 'Global Station Guid',
            'CompanyGUID' => 'Company Guid',
            'XcLevel' => 'Xc Level',
            'LxLevle' => 'Lx Levle',
            'Zyx' => 'Zyx',
            'MajorParentStationGUID' => 'Major Parent Station Guid',
        ];
    }
}
